package org.poseidon.report.domain;

import java.util.Date;
import java.util.Objects;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import org.poseidon.common.annotation.Excel;
import org.poseidon.common.core.domain.BaseEntity;

/**
 * 里程碑对象 bu_milestone
 * 
 * @author gfc
 * @date 2022-02-22
 */
public class BuMilestone extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** $column.columnComment */
    private Long id;

    /** 项目ID */
    @Excel(name = "项目ID")
    private Long projectId;

    /** 里程碑开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "里程碑开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date milesBegin;

    /** 里程碑结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "里程碑结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date milesEnd;

    /** 里程碑负责人 */
    @Excel(name = "里程碑负责人")
    private String milesManager;

    /** 里程碑内容 */
    @Excel(name = "里程碑内容")
    private String milesContent;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setProjectId(Long projectId) 
    {
        this.projectId = projectId;
    }

    public Long getProjectId() 
    {
        return projectId;
    }
    public void setMilesBegin(Date milesBegin) 
    {
        this.milesBegin = milesBegin;
    }

    public Date getMilesBegin() 
    {
        return milesBegin;
    }
    public void setMilesEnd(Date milesEnd) 
    {
        this.milesEnd = milesEnd;
    }

    public Date getMilesEnd() 
    {
        return milesEnd;
    }
    public void setMilesManager(String milesManager) 
    {
        this.milesManager = milesManager;
    }

    public String getMilesManager() 
    {
        return milesManager;
    }
    public void setMilesContent(String milesContent) 
    {
        this.milesContent = milesContent;
    }

    public String getMilesContent() 
    {
        return milesContent;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("projectId", getProjectId())
            .append("milesBegin", getMilesBegin())
            .append("milesEnd", getMilesEnd())
            .append("milesManager", getMilesManager())
            .append("milesContent", getMilesContent())
            .append("createTime", getCreateTime())
            .append("createBy", getCreateBy())
            .append("updateTime", getUpdateTime())
            .append("updateBy", getUpdateBy())
            .toString();
    }
    @Override public boolean equals(Object o) {
        if (this == o)
        {
            return true;
        }
        if (o == null || getClass() != o.getClass())
        {
            return false;
        }
        BuMilestone that = (BuMilestone)o;
        return Objects.equals(id, that.id);
    }

    @Override public int hashCode() {
        return Objects.hash(id);
    }
}
